<?php
// +----------------------------------------------------------------------
// | ThinkPHP [ WE CAN DO IT JUST THINK ]
// +----------------------------------------------------------------------
// | Copyright (c) 2006~2018 http://thinkphp.cn All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: liu21st <liu21st@gmail.com>
// +----------------------------------------------------------------------

Route::get('think', function () {
    return 'hello,ThinkPHP5!';
});

Route::get('hello/:name', 'index/hello');
//Route::get('routeName', 'admin/index/index');

Route::group('auth', [
    //user
    'user_list' => ['thinkAuth\Controller\Users@userList', ['method' => 'get']],
    'ajax_get_user_list' => ['thinkAuth\Controller\Users@ajaxGetUserList', ['method' => 'get,post']],
    'ajax_add_user' => ['thinkAuth\Controller\Users@ajaxAddUser', ['method' => 'get.post']],
    'ajax_del_user' => ['thinkAuth\Controller\Users@ajaxDelUser', ['method' => 'post']],
    'ajax_edit_user' => ['thinkAuth\Controller\Users@ajaxEditUser', ['method' => 'get,post']],
//    'ajax_get_user' => ['thinkAuth\Controller\Users@ajaxGetUserById', ['method' => 'get']],
//    'get_user_all' => ['thinkAuth\Controller\Users@getUsersAll', ['method' => 'get']],
    //auth
    'auth_list' => ['thinkAuth\Controller\Auth@authList', ['method' => 'get']],
    'ajax_get_auth_list' => ['thinkAuth\Controller\Auth@ajaxGetAuthList', ['method' => 'get']],
    'ajax_add_auth' => ['thinkAuth\Controller\Auth@ajaxAddAuth', ['method' => 'get,post']],
    'ajax_edit_auth' => ['thinkAuth\Controller\Auth@ajaxEditAuth', ['method' => 'get,post']],
    'ajax_del_auth' => ['thinkAuth\Controller\Auth@ajaxDelAuth', ['method' => 'post']],
    'get_auth_all/<type?>' => ['thinkAuth\Controller\Auth@getAuthAll', ['method' => 'get']],//获取所有的权限列表
    //group
    'group_list' => ['thinkAuth\Controller\Group@groupList', ['method' => 'get']],
    'ajax_get_group_list' => ['thinkAuth\Controller\Group@ajaxGetGroupList', ['method' => 'get']],
    'ajax_add_group' => ['thinkAuth\Controller\Group@ajaxAddGroup', ['method' => 'get,post']],
    'ajax_edit_group' => ['thinkAuth\Controller\Group@ajaxEditGroup', ['method' => 'get,post']],
    'ajax_del_group' => ['thinkAuth\Controller\Group@ajaxDelGroup', ['method' => 'post']],
    'allocation_auth' => ['thinkAuth\Controller\Group@allocationAuth', ['method' => 'get,post']],
    //'add_group_select_users' => ['thinkAuth\Controller\Group@getGroupsUsersAndRoles', ['method' => 'get']],
    //'ajax_get_group' => ['thinkAuth\Controller\Group@ajaxGetGroupById', ['method' => 'get']],
]);
return [

];
